<template>
  <div style="width:100% " class="x">
    <div class="item-list" style="width:100%" v-for="(item ,index)  in list " :key="index">
      <el-row type="flex" justify="space-between">
        <el-col :span="3" class="title">
          <h3>{{index+1+"L"+item.name}}</h3>
        </el-col>
        <el-col :span="3" class="more">
          <a :href="item.src">更多>></a>
        </el-col>
      </el-row>

      <el-row type="flex" class="content" style="padding:0 20px">
        <el-col
          :span="4"
          style="margin:10px 4px"
          v-for="(work,index)  in item.queryWorks"
          :key="index"
        >
          <el-card :body-style="{ padding: '0px' } " shadow="hover">
            <nuxt-link class="info" :to="'work/'+work.id">
              <img :src="work.coverImage" class="image" />
            </nuxt-link>
            <div style="padding: 14px;">
              <span>{{work.title}}</span>
              <span :class="(work.score)>90?'scope_01':'scope_02'">{{work.score/10}}</span>

              <div class="bottom clearfix">
                <el-tag
                  size="mini"
                  type="info"
                  style="margin-right:2px"
                  v-for="(x,index2) in work.tagList"
                  :key="index2"
                >{{x.udxName}}</el-tag>
              </div>
            </div>
          </el-card>
        </el-col>
      </el-row>

      <el-backtop target=".item-list" :bottom="100">
        <div
          style="{
        height: 100%;
        width: 100%;
        background-color: #f2f5f6;
        box-shadow: 0 0 6px rgba(0,0,0, .12);
        text-align: center;
        line-height: 40px;
        color: #1989fa;
      }"
        >UP</div>
      </el-backtop>
    </div>
  </div>
</template>

<script>
export default {
  methods: {},

  data() {
    return {
      currentDate: new Date()
    };
  },
  computed: {
    list() {
      return this.$store.state.section.list;
    }
  },
 
};
</script>

<style scoped>
.x {
  display: flex;
  flex-direction: column;
}
.info {
  color: #999;
  text-decoration: none;
}
.scope_01 {
  color: #e1251b;
}
.scope_02 {
  color: #ff9a6a;
}
.el-row {
  padding: 2px 0px;
}

.more {
  display: flex;
  justify-content: center;
  align-items: center;
}

.more a {
  color: #e1251b;
  text-decoration: none;
}
.content {
  padding: 40px 10px;
}
.el-col {
  display: flex;
  justify-content: center;
}

.time {
  font-size: 13px;
  color: #999;
}

.bottom {
  margin-top: 13px;
  line-height: 12px;
}

.button {
  padding: 0;
  float: right;
}

.image {
  width: 100%;
  display: block;
}

.clearfix:before,
.clearfix:after {
  display: table;
  content: "";
}

.clearfix:after {
  clear: both;
}
</style>

